home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat5 / migration.z / migration
Encoding:
Text File  |  2002-10-03  |  41.7 KB  |  661 lines

  1.  
  2.  
  3.  
  4. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      migration - dynamic memory migration
  10.  
  11. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  12.      This document describes the dynamic memory migration system available in
  13.      Origin 2000/200 systems. Dynamic migration is not available on other
  14.      Origin platforms. Manual or User migration is available to all Origin
  15.      platforms (see migration(3)).
  16.  
  17.  
  18.    IIIInnnnttttrrrroooodddduuuuccccttttiiiioooonnnn
  19.      Dynamic page migration is a mechanism that provides adaptive memory
  20.      locality for applications running on the Origin 2000/200 systems. The
  21.      Origin 2000/200 hardware implements an algorithm based on comparing
  22.      remote memory access counters to a local memory access counter; when the
  23.      difference between the numbers of remote and local accesses goes beyond a
  24.      preset threshold, an interrupt is generated to inform the operating
  25.      system that a physical memory page is currently experiencing excessive
  26.      remote accesses.
  27.  
  28.  
  29.      Within the interrupt handler the operating system makes a final decision
  30.      whether to migrate the page or not. If it decides to migrate the page,
  31.      the migration is executed immediately. The system may decide not to
  32.      execute the migration due to enforcement of a migration control policy or
  33.      due to lack of resources. Note that use of the dynamic memory migration
  34.      feature will cause a substantial amount of kernel memory to be consumed
  35.      to support this operation.
  36.  
  37.  
  38.      Page migration can also be explicitly requested by users, and in
  39.      addition, it is used to assist the memory coalescing algorithms for
  40.      multiple page size support.
  41.  
  42.  
  43.    MMMMiiiiggggrrrraaaattttiiiioooonnnn MMMMoooodddduuuulllleeeessss
  44.      The migration subsystem is composed of the following modules:
  45.  
  46.      - DDDDeeeetttteeeeccccttttiiiioooonnnn MMMMoooodddduuuulllleeee.... This module monitors memory accesses issued by nodes
  47.        in the system to each physical memory page. In Origin 2000/200 systems
  48.        this module is mostly implemented in hardware. This detection module
  49.        informs the _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l _M_o_d_u_l_e that a page is experiencing
  50.        excessive remote accesses via an interrupt sent to the page's home
  51.        node.
  52.  
  53.      - MMMMiiiiggggrrrraaaattttiiiioooonnnn EEEEnnnnggggiiiinnnneeee MMMMoooodddduuuulllleeee.... This module carries out data movement from a
  54.        current physical memory page to a new page in the node issuing the
  55.        remote accesses.
  56.  
  57.      - MMMMiiiiggggrrrraaaattttiiiioooonnnn CCCCoooonnnnttttrrrroooollll MMMMoooodddduuuulllleeee.... This module decides whether the page should
  58.        be migrated or not, based on migration control policies, defined by
  59.        parameters such as _m_i_g_r_a_t_i_o_n _t_h_r_e_s_h_o_l_d, _b_o_u_n_c_e _d_e_t_e_c_t_i_o_n _a_n_d
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  71.  
  72.  
  73.  
  74.        _p_r_e_v_e_n_t_i_o_n, _d_a_m_p_e_n_i_n_g _f_a_c_t_o_r, and others.
  75.  
  76.      - MMMMiiiiggggrrrraaaattttiiiioooonnnn CCCCoooonnnnttttrrrroooollll PPPPeeeerrrriiiiooooddddiiiicccc OOOOppppeeeerrrraaaattttiiiioooonnnnssss MMMMoooodddduuuulllleeee.... This module executes all
  77.        periodic operations needed for the _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l _M_o_d_u_l_e.
  78.  
  79.      - MMMMeeeemmmmoooorrrryyyy MMMMaaaannnnaaaaggggeeeemmmmeeeennnntttt CCCCoooonnnnttttrrrroooollll IIIInnnntttteeeerrrrffffaaaacccceeee MMMMoooodddduuuulllleeee ((((MMMMMMMMCCCCIIII MMMMoooodddduuuulllleeee)))).... This module
  80.        provides an interface for users to tune the migration policy associated
  81.        with an address space.
  82.  
  83.  
  84.    MMMMiiiiggggrrrraaaattttiiiioooonnnn DDDDeeeetttteeeeccccttttiiiioooonnnn MMMMoooodddduuuulllleeee
  85.      The basic goal of memory migration is to minimize memory access latency.
  86.      In a NUMA system where local memory access latency is smaller then remote
  87.      memory access latency, we can achieve this latency minimization goal by
  88.      moving the data to the node where most memory references are going to be
  89.      issued from.
  90.  
  91.      It would be great to be able to move data to the node where it is going
  92.      to be needed right before it is referenced. Unfortunately, we cannot
  93.      predict the future. However, common programs usually have some amount of
  94.      temporal and spatial locality, which allows us to heuristically predict
  95.      future behavior based on recent past behavior.
  96.  
  97.      The usual procedure used to predict future memory accesses to a page is
  98.      to count the memory references to this page issued by each node in the
  99.      system.  If the accumulated number of remote references becomes
  100.      considerably greater than the number of accumulated local references,
  101.      then it may be beneficial to migrate the page to the remote node issuing
  102.      the references, especially if this remote node will continue accessing
  103.      this same page for a long time.
  104.  
  105.      Origin 2000/200 systems have counters that continuously monitor all
  106.      memory accesses issued by each node in the system to each physical memory
  107.      page. In a 64-node Origin 2000 (128 processors), we have 64 memory access
  108.      counters for every 4-KB low level physical page (4 KB is the size of a
  109.      low level physical page size; software page sizes start at 16KB for
  110.      Origin systems). For every memory access, the counter associated with the
  111.      node issuing the reference is incremented; at the same time, this counter
  112.      is compared to the counter that keeps track of local accesses, and if the
  113.      remote counter exceeds the local counter by a threshold, an interrupt is
  114.      generated advising the Operating System about the existence of a page
  115.      with excessive remote accesses.
  116.  
  117.      Upon reception of the interrupt, the _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l _M_o_d_u_l_e in the
  118.      Operating System decides whether to migrate the page or not.
  119.  
  120.      The threshold that determines how large the difference between remote and
  121.      local counters needs to be in order for the interrupt to be generated is
  122.      stored in a per-node hardware register, which is initialized by the
  123.      Migration Control Module. The _d_e_f_a_u_l_t _s_y_s_t_e_m _t_h_r_e_s_h_o_l_d defined in
  124.      /var/sysgen/mtune/numa by the tunable variables
  125.      nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddeeeeffffaaaauuuulllltttt____tttthhhhrrrreeeesssshhhhoooolllldddd and nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____tttthhhhrrrreeeesssshhhhoooolllldddd____rrrreeeeffffeeeerrrreeeennnncccceeee (see
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  137.  
  138.  
  139.  
  140.      Migration Tunables below), and the threshold specified by users as a
  141.      parameter of a migration policy (mmci(5)), are not directly stored into
  142.      this register due to the fact that different pages on the same node may
  143.      have different migration thresholds. These thresholds are used to
  144.      initialize the reference counters when a page is initialized.
  145.  
  146.  
  147.    MMMMiiiiggggrrrraaaattttiiiioooonnnn EEEEnnnnggggiiiinnnneeee MMMMoooodddduuuulllleeee
  148.      This module transparently moves a page from one physical frame to
  149.      another. The migration engine first verifies the availability of all
  150.      resources needed to realize the migration of a page. If all resources are
  151.      not available, the operation is cancelled.
  152.  
  153.      The data transfer operation is performed using a processor to move
  154.      memory.  Translation lookaside buffer (TLB) shootdowns are done using
  155.      inter-processor interrupts.  TLB shootdowns are needed in order to avoid
  156.      the use of stale translations that may be pointing to the physical memory
  157.      page that contained the data before migration took place. Normally, a TLB
  158.      shootdown operation is performed by sending interrupts to all processors
  159.      in the system with a TLB that may have stale translation entries.
  160.  
  161.  
  162.    MMMMiiiiggggrrrraaaattttiiiioooonnnn CCCCoooonnnnttttrrrroooollll MMMMoooodddduuuulllleeee
  163.      This module decides whether a page should be migrated or not after
  164.      receiving a notification (via an interrupt) from the _M_i_g_r_a_t_i_o_n _D_e_t_e_c_t_i_o_n
  165.      _M_o_d_u_l_e alerting that a page is experiencing excessive remote accesses.
  166.      This decision is based on applicable migration control policies and
  167.      resource availability.
  168.  
  169.      The basic idea behind controlling migration is that it is not always a
  170.      good idea to migrate a page when the memory reference counters are
  171.      telling us that a page is experiencing excessive remote accesses; the
  172.      page may be bouncing back and forth due to poor application behavior, the
  173.      counters may have accumulated too much past knowledge, making them unfit
  174.      to predict near future behavior, the destination node may have little
  175.      free memory, or the path needed to do the migration may be too busy.
  176.  
  177.      The Migration Control Module applies a series of filters to a reference
  178.      counter notification or _m_i_g_r_a_t_i_o_n _r_e_q_u_e_s_t, as enumerated below. All
  179.      tunables mentioned in this list are found in /var/sysgen/mtune/numa.
  180.  
  181.  
  182.      Node Distance Filter        This filter rejects all migration requests
  183.                                  where the distance between the source and the
  184.                                  destination is less than
  185.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmiiiinnnn____ddddiiiissssttttaaaannnncccceeee in
  186.                                  /var/sysgen/mtune/numa. All rejected requests
  187.                                  result in the page being frozen in order to
  188.                                  prevent this request from being re-issued too
  189.                                  soon.
  190.  
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  203.  
  204.  
  205.  
  206.      Memory Pressure Filter      This filter rejects migration requests to
  207.                                  nodes where physical memory is low.  The
  208.                                  threshold for low memory is defined by the
  209.                                  tunable nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeemmmmoooorrrryyyy____lllloooowwww____tttthhhhrrrreeeesssshhhhoooolllldddd, which
  210.                                  defines the minimum percentage of physical
  211.                                  memory that needs to be available in order
  212.                                  for a page to be migrated there. This filter
  213.                                  can be enabled and disabled using the tunable
  214.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeemmmmoooorrrryyyy____lllloooowwww____eeeennnnaaaabbbblllleeeedddd.
  215.  
  216.      Traffic Control Filter      Experimental filter intended to throttle
  217.                                  migration down when the Craylink Interconnect
  218.                                  traffic reaches peak levels. Experiments have
  219.                                  shown that this filter is unnecessary for
  220.                                  Origin 2000/200 systems.
  221.  
  222.      Bounce Control Filter       Sometimes pages may start bouncing due to
  223.                                  poor application behavior or simple page
  224.                                  level false sharing. This filter detects and
  225.                                  freezes bouncing pages. The detection is done
  226.                                  by keeping a count of the number of
  227.                                  migrations per page in a counter that is aged
  228.                                  (periodically decremented by a system
  229.                                  daemon). If the count ever goes above a
  230.                                  threshold, it is considered to be bouncing
  231.                                  and is then frozen. Frozen pages start
  232.                                  melting immediately, so after a period of
  233.                                  time, they are unfrozen and migratable again.
  234.                                  Note the the melting procedure is gradual,
  235.                                  not instantaneous. The bounce control filter
  236.                                  relies on operations executed periodically by
  237.                                  the _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l _P_e_r_i_o_d_i_c _O_p_e_r_a_t_i_o_n_s
  238.                                  _M_o_d_u_l_e described below, for a) aging of the
  239.                                  migration counters and b) melting of frozen
  240.                                  pages. The period of these bounce control
  241.                                  periodic operations is defined by the tunable
  242.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____bbbboooouuuunnnncccceeee____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll. The
  243.                                  default value for this tunable is 0, which
  244.                                  translates into a period such that 4 physical
  245.                                  pages are operated on per tick (10[ms]
  246.                                  interval). Freezing can be enabled and
  247.                                  disabled using the tunable
  248.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ffffrrrreeeeeeeezzzzeeee____eeeennnnaaaabbbblllleeeedddd, and the freezing
  249.                                  threshold can be set using the tunable
  250.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ffffrrrreeeeeeeezzzzeeee____tttthhhhrrrreeeesssshhhhoooolllldddd. This threshold is
  251.                                  specified as a percentage of the maximum
  252.                                  effective freezing threshold value, which is
  253.                                  7 for Origin 2000/200 systems. Melting can be
  254.                                  enabled and disabled using the tunable
  255.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeelllltttt____eeeennnnaaaabbbblllleeeedddd, and the melting
  256.                                  threshold can be set using the tunable
  257.                                  nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeelllltttt____tttthhhhrrrreeeesssshhhhoooolllldddd. The melting
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  269.  
  270.  
  271.  
  272.                                  threshold is expressed as a percentage of the
  273.                                  maximum effective melting threshold value,
  274.                                  which is 7 for Origin 2000/200 systems.
  275.  
  276.      Migration Dampening Filter  This filter minimizes the amount of migration
  277.                                  due to quick temporary remote memory
  278.                                  accesses, such as those that occur when
  279.                                  caches are loaded from a cold state, or when
  280.                                  they are reloaded with a new context. We
  281.                                  implement this dampening flter using a per-
  282.                                  page migration request counter that is
  283.                                  incremented every time we receive a migration
  284.                                  request interrupt, and aged (periodically
  285.                                  decremented) by the _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l
  286.                                  _P_e_r_i_o_d_i_c _O_p_e_r_a_t_i_o_n_s _M_o_d_u_l_e. We migrate a page
  287.                                  only if the counter reaches a value greater
  288.                                  than some dampening threshold. This will
  289.                                  happen only for applications that
  290.                                  continuously generate remote accesses to the
  291.                                  same page during some interval of time. If
  292.                                  the application experiences just a short
  293.                                  transitory sequence of remote accesses, it is
  294.                                  very unlikely that the migration request
  295.                                  counter will reach the threshold value. This
  296.                                  filter can be enabled and disabled using the
  297.                                  tunable nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddaaaammmmppppeeeennnniiiinnnngggg____eeeennnnaaaabbbblllleeeedddd, and the
  298.                                  migration request count threshold can be set
  299.                                  using the tunable nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddaaaammmmppppeeeennnniiiinnnngggg____ffffaaaaccccttttoooorrrr.
  300.  
  301.  
  302.      The memory reference counters are re-initialized to their startup values
  303.      after every reference counter interrupt.
  304.  
  305.  
  306.    MMMMiiiiggggrrrraaaattttiiiioooonnnn CCCCoooonnnnttttrrrroooollll PPPPeeeerrrriiiiooooddddiiiicccc OOOOppppeeeerrrraaaattttiiiioooonnnnssss MMMMoooodddduuuulllleeee
  307.      The _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l _M_o_d_u_l_e relies on several periodic operations. These
  308.      operations are listed below:
  309.  
  310.      - Bounce Control Operations. Age migration counter for freezing and
  311.        melting.
  312.  
  313.      _ Unpegging. Reset memory reference counters that have reached a
  314.        saturation level.
  315.  
  316.      - Queue Control Operations. Age queued outstanding migration requests.
  317.        Experimental, always disabled for production systems.
  318.  
  319.      - Traffic Control Operations. Sample the state of the Craylink
  320.        interconnect and correspondingly adjust the per-node migration
  321.        threshold. Experimental, always disabled for production systems.
  322.  
  323.  
  324.  
  325.  
  326.  
  327.                                                                         PPPPaaaaggggeeee 5555
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  335.  
  336.  
  337.  
  338.      These operations are executed in a loop, triggered once every
  339.      mmmmeeeemmmm____ttttiiiicccckkkk____bbbbaaaasssseeee____ppppeeeerrrriiiioooodddd, a tunable that defines the migration control
  340.      periodic period in terms of system ticks (a system tick is equivalent to
  341.      10 [ms] on Origin systems running IRIX 6.5). This loop of operations may
  342.      be enabled and disabled using the tunable mmmmeeeemmmm____ttttiiiicccckkkk____eeeennnnaaaabbbblllleeeedddd. If migration
  343.      is enabled or users are allowed to use migration, this loop must be
  344.      enabled.
  345.  
  346.      In order to minimize interference with user processes, we limit the
  347.      number of pages operated on in a loop to a few pages, trying to limit the
  348.      time used to less than 20 [us]. Administrators can adjust the time
  349.      dedicated to these periodic operations via the following tunables:
  350.  
  351.      + mmmmeeeemmmm____ttttiiiicccckkkk____bbbbaaaasssseeee____ppppeeeerrrriiiioooodddd
  352.  
  353.      + nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____uuuunnnnppppeeeeggggggggiiiinnnngggg____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll
  354.  
  355.      + nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ttttrrrraaaaffffffffiiiicccc____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll
  356.  
  357.      + nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____bbbboooouuuunnnncccceeee____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll
  358.  
  359.    DDDDeeeessssccccrrrriiiippppttttiiiioooonnnn ooooffff PPPPeeeerrrriiiiooooddddiiiicccc OOOOppppeeeerrrraaaattttiiiioooonnnnssss
  360.      The following list describes the _B_o_u_n_c_e _C_o_n_t_r_o_l _P_e_r_i_o_d_i_c _O_p_e_r_a_t_i_o_n_s in
  361.      detail:
  362.  
  363.      Aging Migration Counters    In order to detect bouncing we keep track of
  364.                                  the number of migrations per page using a
  365.                                  counter that is periodically decremented
  366.                                  (aged). When the counter goes beyond a
  367.                                  threshold, we consider the page to be
  368.                                  bouncing and freeze it.
  369.  
  370.      Aging Migration Request Counters
  371.                                  In order to avoid excessive migration or
  372.                                  bouncing due to short, transitory remote
  373.                                  memry access sequences we have a migration
  374.                                  dampening filter that needs to count several
  375.                                  migration requests within a limited period of
  376.                                  time before it actually lets a real page
  377.                                  migration take place. The time factor is
  378.                                  introduced in the filter by aging the
  379.                                  migration request counters.
  380.  
  381.      Melting Frozen Pages        When a page is frozen we want to eventually
  382.                                  unfreeze it so that it becomes migratable
  383.                                  again. This behavior is desirable because the
  384.                                  events that cause a page to be frozen are
  385.                                  usually temporary. As part of the periodic
  386.                                  operations, we increment a counter per page
  387.                                  to keep track of how long the page has been
  388.                                  frozen. When the counter goes above a
  389.                                  threshold, meaning that the page has been
  390.  
  391.  
  392.  
  393.                                                                         PPPPaaaaggggeeee 6666
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  401.  
  402.  
  403.  
  404.                                  frozen for a sufficient time, we unfreeze the
  405.                                  page, thereby making it migratable again.
  406.  
  407.      The _U_n_p_e_g_g_i_n_g _P_e_r_i_o_d_i_c _O_p_e_r_a_t_i_o_n consists of scanning all the memory
  408.      reference counters looking for those counters that have pegged due to
  409.      reaching their maximum count. When a pegged counter is found, all
  410.      counters associated with that page are restarted.
  411.  
  412.      The current implementation of the _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l mmmmoooodddduuuulllleeee ddddooooeeeessss nnnnooootttt
  413.      eeeexxxxeeeeccccuuuutttteeee _Q_u_e_u_e _C_o_n_t_r_o_l _P_e_r_i_o_d_i_c _O_p_e_r_a_t_i_o_n_s oooorrrr _T_r_a_f_f_i_c _C_o_n_t_r_o_l _P_e_r_i_o_d_i_c
  414.      _O_p_e_r_a_t_i_o_n_s....
  415.  
  416.    PPPPaaaaggggeeee MMMMiiiiggggrrrraaaattttiiiioooonnnn TTTTuuuunnnnaaaabbbblllleeeessss
  417.      This is a list of all the memory migration tunables in
  418.      /var/sysgen/mtune/numa that define the default memory migration policy
  419.      used by the system.
  420.  
  421.      * nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddeeeeffffaaaauuuulllltttt____mmmmooooddddeeee.  This tunable defines the default migration
  422.        mode. It can take the following values:
  423.  
  424.  
  425.               0: MIGR_DEFMODE_DISABLED
  426.                  Migration is completely disabled, users cannot use migration.
  427.  
  428.               1: MIGR_DEFMODE_ENABLED
  429.                  Migration is always enabled, users cannot disable migration.
  430.  
  431.               2: MIGR_DEFMODE_NORMOFF
  432.                  Migration is normally off, users can enable migration for
  433.                  an application. This is the default setting.
  434.  
  435.               3: MIGR_DEFMODE_NORMON
  436.                  Migration is normally on, users can disable migration for
  437.                  an application.
  438.  
  439.               4: MIGR_DEFMODE_LIMITED
  440.                  Migration is normally off for machine configurations with
  441.                  a maximum Numalink distance less than numa_migr_min_maxradius
  442.                  (defined below). Migration is normally on otherwise. Users
  443.                  can override this mode.
  444.  
  445.  
  446.  
  447.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddeeeeffffaaaauuuulllltttt____tttthhhhrrrreeeesssshhhhoooolllldddd.  This threshold defines the minimum
  448.           difference between the local and any remote counter needed to
  449.           generate a migration request interrupt.
  450.  
  451.  
  452.               if ((remote_counter - local_counter) >=
  453.                   ((numa_migr_threshold_reference_value / 100) *
  454.                    numa_migr_default_threshold)) {
  455.                   send_migration_request_intr();
  456.  
  457.  
  458.  
  459.                                                                         PPPPaaaaggggeeee 7777
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  467.  
  468.  
  469.  
  470.               }
  471.  
  472.  
  473.  
  474.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____tttthhhhrrrreeeesssshhhhoooolllldddd____rrrreeeeffffeeeerrrreeeennnncccceeee.  This parameter defines the pegging
  475.           value for the memory reference counters.  It is machine
  476.           configuration dependent. For Origin 2000/200 systems, it can take
  477.           the following values:
  478.  
  479.  
  480.              0: MIGR_THRESHREF_STANDARD = Threshold reference is 2048 (11 bit
  481.                                           counters) Maximum threshold allowed
  482.                                           for systems with STANDARD DIMMS. This
  483.                                           is the default.
  484.              1: MIGR_THRESHREF_PREMIUM =  Threshold reference is 524288 (19-bit
  485.                                           counters) Maximum threshold allowed
  486.                                           for systems with *all* PREMIUM SIMMS.
  487.  
  488.  
  489.  
  490.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmiiiinnnn____mmmmaaaaxxxxrrrraaaaddddiiiiuuuussss.  This tunable is used if
  491.           nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddeeeeffffaaaauuuulllltttt____mmmmooooddddeeee has been set to mode 4
  492.           (MIGR_DEFMODE_LIMITED). For this mode, migration is normally off for
  493.           machine configurations with a maximum Craylink distance less than
  494.           nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmiiiinnnn____mmmmaaaaxxxxrrrraaaaddddiiiiuuuussss Migration is normally on otherwise.
  495.  
  496.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____aaaauuuuttttoooo____mmmmiiiiggggrrrr____mmmmeeeecccchhhh.  This tunable defines the migration
  497.           execution mode for memory reference counter triggered migrations: 0
  498.           for immediate and 1 for delayed. Only the _I_m_m_e_d_i_a_t_e _M_o_d_e (0) is
  499.           currently available.
  500.  
  501.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____uuuusssseeeerrrr____mmmmiiiiggggrrrr____mmmmeeeecccchhhh.  This tunables defines the migration
  502.           execution mode for user requested migrations: 0 for immediate and 1
  503.           for delayed. Only the _I_m_m_e_d_i_a_t_e _M_o_d_e (0) is currently available.
  504.  
  505.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ccccooooaaaallllddddmmmmiiiiggggrrrr____mmmmeeeecccchhhh .  This tunables defines the migration
  506.           execution mode for memory coalescing migrations: 0 for immediate and
  507.           1 for delayed. Only the _I_m_m_e_d_i_a_t_e _M_o_d_e (0) is currently available.
  508.  
  509.      *    nnnnuuuummmmaaaa____rrrreeeeffffccccnnnntttt____ddddeeeeffffaaaauuuulllltttt____mmmmooooddddeeee.  Extended counters are used in application
  510.           profiling (see rrrreeeeffffccccnnnntttt((((5555))))) and to control automatic memory migration.
  511.           This tunable defines the default extended reference counter mode. It
  512.           can take the following values:
  513.  
  514.  
  515.              0: REFCNT_DEFMODE_DISABLED
  516.                 Extended reference counters are disabled, users cannot access
  517.                 the extended reference counters (refcnt(5)). In this case
  518.                 automatic memory migration will not be performed regardless of
  519.                 any other settings.
  520.  
  521.              1: REFCNT_DEFMODE_ENABLED
  522.  
  523.  
  524.  
  525.                                                                         PPPPaaaaggggeeee 8888
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  533.  
  534.  
  535.  
  536.                 Extended reference counters are always enabled, users cannot
  537.                 disable them.
  538.  
  539.              2: REFCNT_DEFMODE_NORMOFF
  540.                 Extended reference counters are normally disabled, users can
  541.                 disable or enable the counters for an application.
  542.  
  543.              3: REFCNT_DEFMODE_NORMON
  544.                 Extended reference counters are normally enabled, users can
  545.                 disable or enable the counters for an application.
  546.  
  547.  
  548.      Note that whenever the reference counters are enabled, a substantial
  549.      amount of kernel memory is allocated internally to support the reference
  550.      counter operations.
  551.  
  552.      *    nnnnuuuummmmaaaa____rrrreeeeffffccccnnnntttt____oooovvvveeeerrrrfffflllloooowwww____tttthhhhrrrreeeesssshhhhoooolllldddd This tunable defines the count at
  553.           which the hardware reference counters notify the operating system of
  554.           a counter overflow in order for the count to be transferred into the
  555.           (software) extended reference counters. It is expresses as a
  556.           percentage of the threshold reference value defined by
  557.           nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____tttthhhhrrrreeeesssshhhhoooolllldddd____rrrreeeeffffeeeerrrreeeennnncccceeee.
  558.  
  559.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmiiiinnnn____ddddiiiissssttttaaaannnncccceeee Minimum distance required by the _N_o_d_e
  560.           _D_i_s_t_a_n_c_e _F_i_l_t_e_r in order to accept a migration request.
  561.  
  562.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeemmmmoooorrrryyyy____lllloooowwww____eeeennnnaaaabbbblllleeeedddd Enable or disable the _M_e_m_o_r_y _P_r_e_s_s_u_r_e
  563.           _F_i_l_t_e_r.
  564.  
  565.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeemmmmoooorrrryyyy____lllloooowwww____tttthhhhrrrreeeesssshhhhoooolllldddd Threshold at which the _M_e_m_o_r_y
  566.           _P_r_e_s_s_u_r_e _F_i_l_t_e_r starts rejecting migration requests to a node. This
  567.           threshold is expressed as a percentage of the total amount of
  568.           physical memory in  a node.
  569.  
  570.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ffffrrrreeeeeeeezzzzeeee____eeeennnnaaaabbbblllleeeedddd Enable or disable the freezing operation in
  571.           the _B_o_u_n_c_e _C_o_n_t_r_o_l _F_i_l_t_e_r.
  572.  
  573.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ffffrrrreeeeeeeezzzzeeee____tttthhhhrrrreeeesssshhhhoooolllldddd Threshold at which a page is frozen. This
  574.           tunable is expressed as a percent of the maximum count supported by
  575.           the migration counters (7 for Origin 2000).
  576.  
  577.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeelllltttt____eeeennnnaaaabbbblllleeeedddd Enable or disable the melting operation in
  578.           the _B_o_u_n_c_e _C_o_n_t_r_o_l _F_i_l_t_e_r.
  579.  
  580.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____mmmmeeeelllltttt____tttthhhhrrrreeeesssshhhhoooolllldddd When a migration counter goes below this
  581.           threshold a page is unfrozen.  This tunable is expressed as a
  582.           percent of the maximum count supported by the migration counters (7
  583.           for Origin 2000).
  584.  
  585.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____bbbboooouuuunnnncccceeee____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll This tunable defines the period
  586.           for the loop that ages the migration counters and the dampening
  587.           counters. It is expressed in terms of _n_u_m_b_e_r _o_f _m_e_m__t_i_c_k_s. The
  588.  
  589.  
  590.  
  591.                                                                         PPPPaaaaggggeeee 9999
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598. mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))                                                      mmmmiiiiggggrrrraaaattttiiiioooonnnn((((5555))))
  599.  
  600.  
  601.  
  602.           mem_tick unit is defined by mmmmeeeemmmm____ttttiiiicccckkkk____bbbbaaaasssseeee____ppppeeeerrrriiiioooodddd _b_e_l_o_w.  _I_f _i_t _i_s
  603.           _s_e_t _t_o _0, _w_e _p_r_o_c_e_s_s _4 _p_a_g_e_s _p_e_r _m_e_m__t_i_c_k. _I_n _t_h_i_s _c_a_s_e, _t_h_e _a_c_t_u_a_l
  604.           _p_e_r_i_o_d _d_e_p_e_n_d_s _o_n _t_h_e _a_m_o_u_n_t _o_f _p_h_y_s_i_c_a_l _m_e_m_o_r_y _p_r_e_s_e_n_t _i_n _a _n_o_d_e.
  605.  
  606.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddaaaammmmppppeeeennnniiiinnnngggg____eeeennnnaaaabbbblllleeeedddd Enable or disable migration dampening.
  607.  
  608.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ddddaaaammmmppppeeeennnniiiinnnngggg____ffffaaaaccccttttoooorrrr The number of migration requests needed
  609.           for a page before migration is actually executed. It is expressed as
  610.           a percentage of the maximum count supported by the migration-request
  611.           counters (3 for Origin 2000).
  612.  
  613.      *    mmmmeeeemmmm____ttttiiiicccckkkk____eeeennnnaaaabbbblllleeeedddd Enable or disabled the loop that executes the
  614.           _M_i_g_r_a_t_i_o_n _C_o_n_t_r_o_l _P_e_r_i_o_d_i_c _O_p_e_r_a_t_i_o_n.
  615.  
  616.      *    mmmmeeeemmmm____ttttiiiicccckkkk____bbbbaaaasssseeee____ppppeeeerrrriiiioooodddd Number of 10[ms] system ticks in one mem_tick.
  617.  
  618.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____uuuunnnnppppeeeeggggggggiiiinnnngggg____ccccoooonnnnttttrrrroooollll____eeeennnnaaaabbbblllleeeedddd Enable or disable the unpegging
  619.           periodic operation
  620.  
  621.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____uuuunnnnppppeeeeggggggggiiiinnnngggg____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll This tunable defines the period
  622.           for the loop that unpegs the hardware memory reference counters. It
  623.           is expressed in terms of _n_u_m_b_e_r _o_f _m_e_m__t_i_c_k_s.  The mem_tick unit is
  624.           defined by mmmmeeeemmmm____ttttiiiicccckkkk____bbbbaaaasssseeee____ppppeeeerrrriiiioooodddd _a_b_o_v_e. _I_f _i_t _i_s _s_e_t _t_o _0, _w_e _p_r_o_c_e_s_s
  625.           _8 _p_a_g_e_s _p_e_r _m_e_m__t_i_c_k. _I_n _t_h_i_s _c_a_s_e, _t_h_e _a_c_t_u_a_l _p_e_r_i_o_d _d_e_p_e_n_d_s _o_n _t_h_e
  626.           _a_m_o_u_n_t _o_f _p_h_y_s_i_c_a_l _m_e_m_o_r_y _p_r_e_s_e_n_t _i_n _a _n_o_d_e.
  627.  
  628.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____uuuunnnnppppeeeeggggggggiiiinnnngggg____ccccoooonnnnttttrrrroooollll____tttthhhhrrrreeeesssshhhhoooolllldddd Hardware memory reference
  629.           counter value at which we consider the counter to be pegged. It is
  630.           expressed as a percent of the maximum count defined by
  631.           numa_migr_threshold_reference.
  632.  
  633.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ttttrrrraaaaffffffffiiiicccc____ccccoooonnnnttttrrrroooollll____eeeennnnaaaabbbblllleeeedddd Enable or disable the _T_r_a_f_f_i_c
  634.           _C_o_n_t_r_o_l _F_i_l_t_e_r. This is an experimental module, and therefore it
  635.           should always be disabled.
  636.  
  637.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ttttrrrraaaaffffffffiiiicccc____ccccoooonnnnttttrrrroooollll____iiiinnnntttteeeerrrrvvvvaaaallll Traffic control period.
  638.           Experimental module.
  639.  
  640.      *    nnnnuuuummmmaaaa____mmmmiiiiggggrrrr____ttttrrrraaaaffffffffiiiicccc____ccccoooonnnnttttrrrroooollll____tttthhhhrrrreeeesssshhhhoooolllldddd Traffic control threshold for
  641.           kicking the batch migration of enqueued migration requests.
  642.           Experimental module.
  643.  
  644.  
  645. FFFFIIIILLLLEEEESSSS
  646.      /var/sysgen/mtune/numa
  647.  
  648. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  649.      numa(5), mtune(4), refcnt(5), mmci(5), migration(3), nstats(1), sn(1),
  650.      topology(1).
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.                                                                        PPPPaaaaggggeeee 11110000
  658.  
  659.  
  660.  
  661.